<meta charset="UTF-8">

<input id="t" placeholder="备忘标题" />
<br> <br>
<textarea name="" id="c" cols="88" rows="12" placeholder="备忘内容"></textarea>
<br> <br>
<button onclick="save()">保存<tton>



<script>
    function save(){
        //Ajax
        var request=new XMLHttpRequest();
        request.open("get","/add_beiwang?title="+t.value+"&content="+c.value);
        request.send();
        request.onreadystatechange=function(){
            if(request.readyState==4&&request.status==200){
                alert("新增成功！")
            }
        }
    }
</script>
